import { defineConfig } from "vite";
export default () => {
	return defineConfig({
		css: {
			postcss: {
				plugins: [
					// 前缀追加
					require("autoprefixer")({
						overrideBrowserslist: [
							"Android 4.1",
							"iOS 7.1",
							"Chrome > 31",
							"ff > 31",
							"> 1%",
						],
						grid: true,
					}),
					require("postcss-flexbugs-fixes"),
				],
			},
		},
		server: {
			proxy: {
				'^/api': {
					target: 'http://stg2-ele-manage-web-api.daikuan.qihoo.net',
					changeOrigin: true
				},
				'^/mas/': {
					target: 'http://mktcms-web-uat.daikuan.qihoo.net',
					changeOrigin: true
				},
				'^/mms/': {
					target: 'http://mktcms-web-uat.daikuan.qihoo.net',
					changeOrigin: true
				}
			}
		}
	});
};
